package com.bawei.rk_01.Room

import androidx.room.Dao
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query
import androidx.room.Update


@Dao
interface MoneyDao {

    @Insert(onConflict = OnConflictStrategy.REPLACE)
    fun insert(moneyEntity: MoneyEntity)

    @Update
    fun update(moneyEntity: MoneyEntity)

    @Query("select * from money where userid = :userid")
    fun query(userid:Int) :MoneyEntity

}